<template>
  <div class="gva-table-box">
    <div style="display:flex">
      <div style="flex:2">
        预览大致样式
      </div>

      <div style="flex:4">
        <div class=" iphone-mobile "
             style="float:left">
          <iframe style="width: 300px; height: 680px;padding-top:60px"
                  scrolling="auto"
                  :src="url"
                  frameborder="0"
                  id="iframe">

          </iframe>
        </div>
      </div>

    </div>

  </div>
</template>

<script  setup>
import { ref, reactive, nextTick } from 'vue'
import { useRoute, useRouter } from "vue-router"
const router = useRouter()
const uuid = ref(router.currentRoute.value.query.uuid)
defineOptions({
  name: 'QuestionnaireContentView',
})
//获取问卷网址
console.log(window.location.href.substring(0, window.location.href.indexOf("/questionnaireInfo")))
const url = ref(window.location.href.substring(0, window.location.href.indexOf("/questionnaireInfo"))
  + "/questionnaireContent?" + "uuid=" + uuid.value)
</script>
<style scoped>
.iphone-mobile {
  width: 390px;
  height: 844px;
  margin: 0 auto;
  /* padding: 80px 20px; */
  margin-top: -25px;
  background: url('@/assets/phone/iphone.png') no-repeat;
  background-size: 100%;
  text-align: center;
}
</style>

